<include file="Public:top" />

<link rel='stylesheet' type='text/css' href='__PUBLIC__/statics/css/admin_style.css'>
<style type="text/css">.input{ font-size:14px}</style> 

<script type="text/javascript">
	function showtab(mid,val,n){
	 	for(var i=1;i<=n;i++){
			$('#'+mid+i).hide();
		}
		$('#'+mid+val).show();
	}
	
	function showtabs(mid,val,n){
	    if(val==1){
			for(var i=1;i<=n;i++){
				$('#'+mid+i).show();
			}
		}else{
			for(var i=1;i<=n;i++){
				$('#'+mid+i).hide();
			}
		}
	}
	
	$(document).ready(function(){

		$('#html_cache_on').change(function(){
			showtabs('html',$(this).val(),4);
		});
		<if condition="C('home.html_cache_on') eq '1'">showtabs('html',1,4);</if>
	});
</script>

</head>
<body>
<table width="98%" border="0" cellpadding="4" cellspacing="1" class="table">
<form action="{:U('Config/cache')}" method="post" id="gxform"> 
<tr class="table_title"><td colspan="4">网站缓存设置</td></tr>

<tr class="ji">
  <td class="left">缓存功能</td>
  <td colspan="3">
  	<select name="con[html_cache_on]" id="html_cache_on" class="w100">
	  <option value="1" <if condition="C('home.html_cache_on') eq '1'">selected="selected"</if>>开启</option>
	  <option value="0" <if condition="C('home.html_cache_on') eq '0'">selected="selected"</if>>关闭</option>
  	</select>
  <span id="html1" style="display:none">后缀名：
	  	<select name="con[html_file_suffix]">
		  <option value=".html" <if condition="C('home.html_file_suffix') eq '.html'">selected="selected"</if>>.html</option>
		  <option value=".htm" <if condition="C('home.html_file_suffix') eq '.htm'">selected="selected"</if>>.htm</option>
		  <option value=".shtml" <if condition="C('home.html_file_suffix') eq '.shtml'">selected="selected"</if>>.shtml</option>
		  <option value=".shtm" <if condition="C('home.html_file_suffix') eq '.shtm'">selected="selected"</if>>.shtm</option>
	  	</select>
  	</span>
  </td>
</tr>     
<tr class="tr" id="html2" style="display:none">
  <td class="left">首页缓存时间(小时)</td>
  <td colspan="3"><input type="text" name="con[html_cache_index]" maxlength="6" value="{:C('home.html_cache_index')}" class="w100">
  </td>
</tr>
<tr class="tr" id="html3" style="display:none">
  <td class="left">列表页缓存时间(小时)</td>
  <td colspan="3"><input type="text" name="con[html_cache_cate]" maxlength="6" value="{:C('home.html_cache_cate')}" class="w100">
  </td>
</tr>
<tr class="tr" id="html4" style="display:none">
  <td class="left">专辑页缓存时间(小时)</td>
  <td colspan="3"><input type="text" name="con[html_cache_album]" maxlength="6" value="{:C('home.html_cache_album')}" class="w100">
  </td>
</tr>     
<tr class="tr">
  <td colspan="4"><input type="hidden" name="setting_sub" value="true">
    <input class="bginput" type="submit" name="submit" value="提交">
  </td>
</tr>
</form>
</table>
<include file="footer" />
</body>
</html>